package com.maotouying.owlextremeapp;

import android.view.View;
import android.widget.Button;

import com.maotouying.owlextremeapp.activity.BaseActivity;
import com.maotouying.owlextremeapp.activity.LoginActivity;
import com.maotouying.owlextremeapp.activity.RegisterActivity;

public class MainActivity extends BaseActivity {

    private Button btnLogin;
    private Button btnRegister;



    @Override
    protected int initLayout() {
        return R.layout.activity_main;
    }

    @Override
    protected void initView() {
        btnLogin = findViewById(R.id.btn_login);
        btnLogin.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                navigateTo(LoginActivity.class);
            }
        });
    }

    @Override
    protected void initDate() {
        btnRegister = findViewById(R.id.btn_register);
        btnRegister.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                // Intent intent = new Intent(MainActivity.this, RegisterActivity.class);
                // startActivity(intent);
                navigateTo(RegisterActivity.class);
            }
        });
    }
}